<?php

class Reserva extends MY_Model {
 
    function Reserva()
    {
        // Call the Model constructor
        parent::MY_Model();

	$this->nombreTabla = "reserva";
	$this->idT1= "idReserva";
	$this->nombreCampo="fecha";


		$this->campos[] = array("realname" => "idCliente",
					"clase" => "partof",
					"label" => "Cliente",
					"modelo" => "Clientes",
					"rules" => "required|integer");

		$this->campos[] = array("realname" => "idMesa",
					"clase" => "opciones",
					"label" => "Mesa",
					"modelo" => "Mesa",
					"rules" => "required|integer");

		$this->campos[] = array("realname" => "fecha",
					"clase" => "date",
					"label" => "Dia",
					"rules" => "required|min_length[3]|max_length[30]");

		$this->campos[] = array("realname" => "hora",
					"clase" => "time",
					"label" => "Hora",
					"rules" => "required|min_length[3]|max_length[5]");
		
		$this->campos[] = array("realname" => "comentarioAntes",
					"clase" => "textarea",
					"label" => "Comentario",
					"rules" => "min_length[3]|max_length[1000]|alpha_numeric_space");

		$this->campos[] = array("realname" => "comentarioDespues",
					"clase" => "textarea",
					"label" => "Comentario Despues",
					"rules" => "min_length[3]|max_length[1000]|alpha_numeric_space");
		
		$this->campos[] = array("realname" => "confirmado",
					"clase" => "text",
					"label" => "Confirmado(0-No,1-Si)",
					"rules" => "exact_length[1]");
			
		$this->campos[] = array("realname" => "numeroPersonas",
					"clase" => "text",
					"label" => "Cantidad de personas",
					"rules" => "required|numeric|max_length[11]");
		

    }
     
}


?>
